# Maintainer: Andreas Radke <andyrtr@archlinux.org>
# Contributor: WorMzy Tykashi <wormzy.tykashi@gmail.com>

pkgname=lprint
pkgver=1.0
pkgrel=1
pkgdesc="Label Printer Application"
arch=('x86_64')
url="https://www.msweet.org/lprint/"
license=('Apache' 'custom')
depends=('libcups' 'libpng' 'libusb' 'pam')
source=("https://github.com/michaelrsweet/lprint/releases/download/v${pkgver}/${pkgname}-${pkgver}.tar.gz"{,.sig})
validpgpkeys=('845464660B686AAB36540B6F999559A027815955')  # "Michael R Sweet <michael.r.sweet@gmail.com>"
sha256sums=('52a34d4a17accdc90aa32a29faf8da3493c274d838fdb86f0034ceaac83b5a32'
            'SKIP')
build() {
  cd ${pkgname}-${pkgver}
  ./configure --prefix=/usr
  make
}

check() {
   cd "$pkgname-$pkgver"
   #make -k check
}

package() {
  cd ${pkgname}-${pkgver}
  make DESTDIR="${pkgdir}" install
  # add license + exception
  install -m644 -Dt "${pkgdir}/usr/share/licenses/${pkgname}" {LICENSE,NOTICE}
}
